package org.misty.seckill.vo;

import lombok.*;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;

@Getter
@Setter
@ToString
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class LoginVo {
  // input properties

  @NotBlank
  @Pattern(regexp = "\\d+")
  private String mobile;

  @NotBlank
  private String password;

  // output properties

  private String sessionToken;

  /**
   * in seconds
   */
  private int sessionExpiry;
}
